This guide walks you through cloning the project, connecting it to Supabase, and starting the development server.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/santiagodc8/tu_perfil.net/llms.txt
Use this file to discover all available pages before exploring further.
You need Node.js 18 or later, npm, and a free Supabase account before you begin.
Install dependencies
Install all Node.js dependencies with npm:This installs Next.js 14, the Supabase SSR client, TipTap editor extensions, Resend, Tailwind CSS, and all other packages declared in
package.json.Create a Supabase project and run the migration
- Go to supabase.com and create a new project.
- Once the project is ready, open SQL Editor in the Supabase dashboard.
- Copy the contents of
supabase/migrations/001_initial_schema.sqland run it. This creates thecategories,articles, andcontactstables, enables RLS, creates thearticle-imagesstorage bucket, and seeds the six initial categories.
The remaining migration files (
002_add_featured.sql through 019_ad_tracking.sql) add features incrementally. Run them in order if you want the full schema including tags, comments, newsletter subscribers, ads, and page-view analytics. You can paste them all into the SQL Editor one at a time.handle_new_user trigger automatically assigns the admin role to the first user created.Configure environment variables
Copy the example file and fill in your Supabase credentials:Open You can find all three values in your Supabase dashboard under Settings → API:
.env.local and set the three required variables:.env.local
| Variable | Where to find it |
|---|---|
NEXT_PUBLIC_SUPABASE_URL | Project URL |
NEXT_PUBLIC_SUPABASE_ANON_KEY | anon / public key |
SUPABASE_SERVICE_ROLE_KEY | service_role key (keep this secret) |
Start the development server
Run the Next.js development server:Next.js starts on port 3000 by default.
Open the app in your browser
You now have two surfaces running:
Log in at
| URL | Description |
|---|---|
http://localhost:3000 | Public news portal (home, articles, categories, search, contact) |
http://localhost:3000/admin | Admin dashboard (redirects to /admin/login if unauthenticated) |
/admin/login with the credentials you created in Supabase. After a successful login the middleware redirects you to /admin, where you can manage articles, categories, comments, and more.Available npm scripts
| Command | Description |
|---|---|
npm run dev | Start the development server |
npm run build | Create a production build |
npm run start | Run the production build locally |
npm run lint | Run ESLint |
Next steps
Architecture overview
Learn how the public site, admin panel, and database fit together.
Database schema
Explore all tables, RLS policies, and RPC functions.
Authentication
Understand how middleware, sessions, and roles work.
Deploy to Vercel
Ship TuPerfil.net to production in a few steps.
